package com.you.consumer.service.impl;

import com.you.nettty.rpc.proxy.RpcProxy;
import com.you.service.api.IHelloRpcService;
import jdk.nashorn.internal.runtime.ECMAException;

/**
 * 测试通过RPC远程调用服务
 */
public class TestRpcCallServiceImpl {

    public static void main(String[] args) throws Exception {
        //通过RPC远程调用服务
        IHelloRpcService helloRpcService = RpcProxy.create(SelfHelloRpcServiceImpl.class);
        System.out.println(helloRpcService.helloRpcService("你好RPC测试！"));
    }
}
